package org.leyi.shop.runner;

import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.leyi.shop.service.OrderService;
import org.springframework.boot.CommandLineRunner;
import org.springframework.stereotype.Component;

/**
 *
 * description:  启动订单消费线程
 * @author  lenovo
 * create 2024/5/8-21:07 */
@Component
@Slf4j
public class StartOrderDelayQueueListener implements CommandLineRunner {
    @Resource
    private OrderService orderService;
    @Override
    public void run(String... args) {
        orderService.startConsumeOrderQueueThread();
        log.info("订单消费线程开始启动");
    }
}
